
\documentclass{article}
\usepackage{pgfplots}
\usepackage{pgfplots.assert}
    \pgfplotsset{compat=newest}

\begin{document}

\makeatletter
{
	\pgfkeys{/pgf/fpu}
	\pgfmathdeclarefunction{ABC}{1}{
		\pgfplotsassertequalstok{aBc}{#1}{}%
		\def\pgfmathresult{1}%
	}
	\pgfmathparse{ABC("aBc")}
	\pgfplotsassertequalstok{1Y1.0e0]}{\pgfmathresult}{}%
}


\pgfplotsforeachtodomain{-5,-4.5833333,...,5}
\pgfplotsassertequalstok{{-5:5}{25}}{{\pgfplotsretval}{\pgfplotsretvalb}}{Fail}%

\pgfplotsforeachtodomain{-1,-0.9,...,1}
\pgfplotsassertequalstok{{-1:1}{21}}{{\pgfplotsretval}{\pgfplotsretvalb}}{Fail}%

\pgfplotsforeachtodomain{-1,-0.9,...,1,2,3}
\pgfplotsassertequalstok{{}{}}{{\pgfplotsretval}{\pgfplotsretvalb}}{Fail}%

\pgfplotsforeachtodomain{-1,-0.9,...,1.05}
\pgfplotsassertequalstok{{}{}}{{\pgfplotsretval}{\pgfplotsretvalb}}{Fail}%
\end{document}
